package name.cyrax.red.jpv.impl.adapters;

import name.cyrax.red.jpv.api.adapters.NumericAccessor;
import name.cyrax.red.jpv.api.funcs.info.ValueType;

public abstract class IntegerImpl extends NumericImpl<Integer>
{

	@Override public <T> T detectType(NumericAccessor<T> accessor)
	{
		return accessor.asInteger(asInteger());
	}

	@Override public double getDouble(int index)
	{
		return getInteger(index);
	}

	@Override public long getLong(int index)
	{
		return getInteger(index);
	}

	@Override public Integer getNumber(int index)
	{
		return getInteger(index);
	}
	
	@Override public ValueType getUnderlyingType()
	{
		return ValueType.INTEGER;
	}
}
